package com.itheima.bos.service.base.impl;

import java.util.List;

import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.data.domain.Page;
import org.springframework.data.domain.PageRequest;
import org.springframework.data.domain.Pageable;
import org.springframework.data.jpa.domain.Specification;
import org.springframework.stereotype.Service;
import org.springframework.transaction.annotation.Transactional;

import com.itheima.bos.dao.base.AreaRepositry;
import com.itheima.bos.domain.base.Area;
import com.itheima.bos.service.base.IAreaService;
@Service
@Transactional
public class AreaServiceImpl implements IAreaService {
	
	@Autowired
	private AreaRepositry areaRepositry;

	@Override
	public void save(List<Area> areas) {
		areaRepositry.save(areas);
	}

	@Override
	public Page<Area> findAll(Specification<Area> specification,
			Pageable pageable) {
		
		return areaRepositry.findAll(specification,pageable);
	}

	@Override
	public void save(Area model) {
		areaRepositry.save(model);
		
	}

	



	

}
